#pragma once

#include <vector>

using namespace std;

class Neuron 
{
    public:
        vector<double> weights;
        
        Neuron();
        
        Neuron(int inputs);
};
      
class Layer 
{ 
    public:
        vector<Neuron> neurons;
        vector<double> output;
        vector<double> delta;
        
        Layer();
        
        Layer(int neurons_num, int inputs_num);
};      

class Network 
{
    public:
        vector<Layer> layers;
        int networkInputs;
        
        Network(int inputs, int hidden1, int outputs);
        
        Network(char* fileName);
        
        double sigmoid(double num);
        
        double sigmoidDerivative(double num);
        
        double train(vector<double> initialInput, vector<double> expected);
        
        vector<double> test(vector<double> initialInput);
        
        void saveWeights(char* fileName);
};
